Naming
For:
- Table names
- Column names
Always use
PascalCase, so:
✅Correct
CREATE TABLE ExampleTable (
MyColumn VARCHAR(255) NOT NULL,
ExampleText INT NOT NULL
);
All column and table names are in PascalCase.
❌Wrong
CREATE TABLE exAmPle_TABLE (
IncO-rr_ectllynamedCOLUMN VARCHAR(255) NOT NULL
);
Column names and table names shouldn't use other types.
For:
- SQL Statements
- All types and keywords (
NOT,NULL,VARCHAR,CREATE) Always useUPPERCASE/SCREAMINGCASE, so:
✅Correct
CREATE TABLE ExampleTable (
MyColumn VARCHAR(255) NOT NULL
);
Types and keywords are using UPPERCASE/SCREAMINGCASE
❌Wrong
cReaTe table ExampleTable (
MyColumn VarChar(255) Not Null check (1 == 1)
);
Types and keywords shouldn't use other types.